﻿namespace iMarkdown.Blocks;

public class BoldBlock : Block
{
    public List<Block> Blocks { get; } = [];
    public override string ToHtml()
    {
        return $"<strong>{ListToHtml(Blocks)}</strong>";
    }
}

public class ItalicBlock : Block
{
    public List<Block> Blocks { get; } = [];
    public override string ToHtml()
    {
        return $"<em>{ListToHtml(Blocks)}</em>";
    }
}

public class DeleteBlock : Block
{
    public List<Block> Blocks { get; } = [];
    public override string ToHtml()
    {
        return $"<s>{ListToHtml(Blocks)}</s>";
    }
}

public class StringBlock : Block
{
    public override string ToHtml()
    {
        return Context;
    }
}